<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2018/12/23 0023
  Time: 9:52
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
    request.setCharacterEncoding("utf-8");
%>
<html>
<head>
    <title>Choose条件选择标签</title>
</head>
<body>

<c:if var="time" test="${empty param.time}">
    <form action="" method="post">
        <input type="number" name="time">
        <input type="submit" >
    </form>
</c:if>
<c:if test="${!time}">

    <c:choose>
        <c:when test="${param.time<=9}">
            <c:out value="早上好!现在是${param.time}点"></c:out>
        </c:when>
        <c:when test="${param.time<=13 && param.time>9}">
            <c:out value="中午好!现在时间是${param.time}"></c:out>
        </c:when>
        <c:when test="${param.time<=16&&param.time>13}">
            <c:out value="下午好!现在时间是${param.time}"></c:out>
        </c:when>
        <c:when test="${param.time<=24&&param.time>16}">
            <c:out value="晚上好!现在时间是${param.time}"></c:out>
        </c:when>
    </c:choose>


</c:if>


</body>
</html>
